import React, { Fragment } from 'react'
import HomePage from './pages/homePage/index.js'
import DetailPage from './pages/detailPage/index.js'
import { HashRouter, Redirect, Route, Switch } from 'react-router-dom'

function App() {
    return (
        <Fragment>
            <HashRouter>
                <Switch>
                    <Route path="/detail" component={DetailPage}/>
                    <Route path="/home" component={HomePage}/>
                    <Route exact path="/" component={HomePage}/>
                    <Redirect to={"/home"}/>
                </Switch>
            </HashRouter>
        </Fragment>
    )
}

export default App
